<div class="layuimini-container">
    <form id="app-form" class="layui-form layuimini-form">
        <div class="layui-form-item">
            <label class="layui-form-label">接口标题</label>
            <div class="layui-input-block">
                <input type="text" name="info" class="layui-input" lay-verify="required" lay-reqtext="请输入接口标题" placeholder="请输入接口标题" value="{$row['info']}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label required">真实地址</label>
            <div class="layui-input-block">
                <input type="text" name="apiname" class="layui-input" lay-verify="required" lay-reqtext="真实地址" placeholder="真实地址" value="{$row['apiname']}">
                <tip>控制器名/方法名。如：user/index</tip>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">所属分组</label>
            <div class="layui-input-block">
                <select name="group">
                    {foreach $groups as $k=>$vo}
                    <option value="{$vo.id}" {if $row['group'] == $vo.id } selected {/if}>{$vo.name|raw}</option>
                    {/foreach}
                </select>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">接口映射</label>
            <div class="layui-input-block">
                <input type="text" name="hash" class="layui-input" lay-reqtext="请输入接口映射" placeholder="请输入接口映射" value="{$row['hash']}" disabled>
                <tip>系统自动生成，不允许修改</tip>
            </div>
        </div>

       
        <div class="layui-form-item">
            <label class="layui-form-label">请求方式</label>
            <div class="layui-input-block">
                <input type="radio" name="method" lay-skin="primary" title="不限" value="0" {if $row['method'] == 0} checked {/if}>
                <input type="radio" name="method" lay-skin="primary" title="Post" value="1" {if $row['method'] == 1} checked {/if}>
                <input type="radio" name="method" lay-skin="primary" title="Get" value="2" {if $row['method'] == 2} checked {/if}>
            </div>
        </div>
      
        
        <div class="layui-form-item">
            <label class="layui-form-label">登录验证</label>
            <div class="layui-input-block">
                <input type="radio" name="needlogin" lay-skin="primary" title="忽略验证" value="0"  {if $row['needlogin'] == 0} checked {/if}>
                <input type="radio" name="needlogin" lay-skin="primary" title="需要验证" value="1"  {if $row['needlogin'] == 1} checked {/if}>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">运行环境</label>
            <div class="layui-input-block">
                <input type="radio" name="istest" lay-skin="primary" title="生产模式" value="0" {if $row['istest'] == 0} checked {/if}>
                <input type="radio" name="istest" lay-skin="primary" title="测试模式" value="1" {if $row['istest'] == 1} checked {/if}>
            </div>
        </div>
        <div class="layui-form-item layui-form-text">
            <label class="layui-form-label">接口详细说明</label>
            <div class="layui-input-block">
                <textarea name="readme" class="layui-textarea" placeholder="请输入接口详细说明">{$row['readme']}</textarea>
            </div>
        </div>
        <div class="layui-form-item layui-form-text">
            <label class="layui-form-label">返回数据示例</label>
            <div class="layui-input-block">
                <textarea name="returnstr" class="layui-textarea" placeholder="请输入返回数据示例">{$row['returnstr']}</textarea>
            </div>
        </div>
        
        <div class="hr-line"></div>
        <div class="layui-form-item text-center">
            <button type="submit" class="layui-btn layui-btn-normal layui-btn-sm" lay-submit>确认</button>
        </div>

    </form>
</div>